package com.xinqi.modules.sys.dict.convert;

import com.xinqi.common.mapstruct.CommonConvertConfig;
import com.xinqi.modules.sys.dict.domain.SchoolEntity;
import com.xinqi.modules.sys.dict.dto.req.SchoolCreateDTO;
import com.xinqi.modules.sys.dict.dto.req.SchoolUpdateDTO;
import com.xinqi.modules.sys.dict.dto.rsp.SchoolResultDTO;
import org.mapstruct.Mapper;
import org.mapstruct.MappingTarget;

/**
 * 学校表转换
 *
 * @author: wenjie
 * @date: 2023/05/19
 */
@Mapper(config = CommonConvertConfig.class)
public abstract class SchoolConvert {
    public abstract SchoolEntity create(SchoolCreateDTO s);

    public abstract SchoolEntity update(SchoolUpdateDTO s, @MappingTarget SchoolEntity t);

    public abstract SchoolEntity update(SchoolUpdateDTO s);

    public abstract SchoolResultDTO convert(SchoolEntity s);
}
